package petrochina.company.electric.model;

import android.os.Parcel;
import android.os.Parcelable;

public class TaskApplyResult implements Parcelable {

    // 任务人Id
    private long staffId;
    // 任务内容
    private String taskContent;
    // 线路id
    private long circuitId;
    // 区域id
    private long regionId;
    // 断路器id
    private long equipId;
    // 电压断路器Id  以逗号分隔id
    private String electricEquips;
    // 储能断路器Id  以逗号分隔id
    private String energyEquips;

    public TaskApplyResult(long staffId, String taskContent, long circuitId, long regionId, long equipId, String electricEquips, String energyEquips) {
        this.staffId = staffId;
        this.taskContent = taskContent;
        this.circuitId = circuitId;
        this.regionId = regionId;
        this.equipId = equipId;
        this.electricEquips = electricEquips;
        this.energyEquips = energyEquips;
    }

    public long getStaffId() {
        return staffId;
    }

    public void setStaffId(long staffId) {
        this.staffId = staffId;
    }

    public String getTaskContent() {
        return taskContent;
    }

    public void setTaskContent(String taskContent) {
        this.taskContent = taskContent;
    }

    public long getCircuitId() {
        return circuitId;
    }

    public void setCircuitId(long circuitId) {
        this.circuitId = circuitId;
    }

    public long getRegionId() {
        return regionId;
    }

    public void setRegionId(long regionId) {
        this.regionId = regionId;
    }

    public long getEquipId() {
        return equipId;
    }

    public void setEquipId(long equipId) {
        this.equipId = equipId;
    }

    public String getElectricEquips() {
        return electricEquips;
    }

    public void setElectricEquips(String electricEquips) {
        this.electricEquips = electricEquips;
    }

    public String getEnergyEquips() {
        return energyEquips;
    }

    public void setEnergyEquips(String energyEquips) {
        this.energyEquips = energyEquips;
    }

    public static Creator<TaskApplyResult> getCREATOR() {
        return CREATOR;
    }

    @Override
    public String toString() {
        return "TaskApplyResult{" +
                "staffId=" + staffId +
                ", taskContent='" + taskContent + '\'' +
                ", circuitId=" + circuitId +
                ", regionId=" + regionId +
                ", equipId=" + equipId +
                ", electricEquips='" + electricEquips + '\'' +
                ", energyEquips='" + energyEquips + '\'' +
                '}';
    }

    @Override
    public int describeContents() {
        return 0;
    }

    @Override
    public void writeToParcel(Parcel dest, int flags) {
        dest.writeLong(this.staffId);
        dest.writeString(this.taskContent);
        dest.writeLong(this.circuitId);
        dest.writeLong(this.regionId);
        dest.writeLong(this.equipId);
        dest.writeString(this.electricEquips);
        dest.writeString(this.energyEquips);
    }

    public void readFromParcel(Parcel source) {
        this.staffId = source.readInt();
        this.taskContent = source.readString();
        this.circuitId = source.readLong();
        this.regionId = source.readLong();
        this.equipId = source.readLong();
        this.electricEquips = source.readString();
        this.energyEquips = source.readString();
    }

    public TaskApplyResult() {
    }

    protected TaskApplyResult(Parcel in) {
        this.staffId = in.readInt();
        this.taskContent = in.readString();
        this.circuitId = in.readLong();
        this.regionId = in.readLong();
        this.equipId = in.readLong();
        this.electricEquips = in.readString();
        this.energyEquips = in.readString();
    }

    public static final Creator<TaskApplyResult> CREATOR = new Creator<TaskApplyResult>() {
        @Override
        public TaskApplyResult createFromParcel(Parcel source) {
            return new TaskApplyResult(source);
        }

        @Override
        public TaskApplyResult[] newArray(int size) {
            return new TaskApplyResult[size];
        }
    };
}
